package org.feng.feign;

import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.feng.entity.Menu;
import org.feng.base.entity.Result;
import org.feng.service.MenuService;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author 冯帅
 * @des TODO
 * @date 2022/2/7 9:56
 * @email 15612509687@163.com
 */
@Service
@AllArgsConstructor
@RestController
@Slf4j
public class MenuFeignImpl implements MenuFeign {

    private final MenuService menuService;

    @Override
    public Result<List<Menu>> getButtons(Long roleId) {
        return Result.success(menuService.getButtons(roleId));
    }
}
